package com.hsc.www;

import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

import java.util.Arrays;


    @Aspect
    @Component
    public class RedisAspect {


        @Pointcut("execution(* org.springframework.data.redis.core.RedisTemplate+.*(..))")
        public void pointCut() {

        }


        @Before("pointCut()")
        public void before(JoinPoint joinPoint) throws Throwable {
            System.out.println(Arrays.toString(joinPoint.getArgs()));
        }
    }


